import {ApiFetch} from "../api/apiHandler";
import {BaseUrl} from "../constant/constant";

class AdminModel {
    constructor() {
        this.url = BaseUrl
    }

    add(params) {
        let end = this.url + 'adduser'
        let req = new ApiFetch(end)
        return req.fetch(params)
    }

    delete(params) {
        let end = this.url + 'deleteuser'
        let req = new ApiFetch(end)
        return req.fetch(params)
    }

    get(params) {
        let end = this.url + 'getuser'
        let req = new ApiFetch(end)
        return req.fetch(params)
    }
}

export default AdminModel
